import Vue from 'vue'
import Router from 'vue-router'


Vue.use(Router)

export default new Router({
  routes: [

    {
      path: '/',
      redirect: '/newIndex',
      component: () => import('../views/home.vue'),
      children: [
        {
          path: '/newIndex',//新首页
          name: 'newIndex',
          component: () => import('../views/newIndex.vue'),
        },
        {
          path: '/academyList',//院校
          name: 'academyList',
          component: () => import('../views/academyList.vue'),
        },
        {
          path: '/academyDetails/:id',//院校详情
          name: 'academyDetails',
          component: () => import('../views/academyDetails.vue'),
        },
        {
          path: '/newsDetaisl/:id',//新闻详情
          name: 'newsDetaisl',
          component: () => import('../views/newsDetaisl.vue'),
        },
        {
          path: '/newsList',//新闻
          name: 'newsList',
          component: () => import('../views/newsList.vue'),
        },
        {
          path: '/lesson',//课程
          name: 'lesson',
          component: () => import('../views/lesson.vue'),
        },
        {
          path: '/lessonIntroduce/:id',//课程介绍
          name: 'lessonIntroduce',
          component: () => import('../views/lessonIntroduce.vue'),
        },
        {
          path: '/about',//关于我们
          name: 'about',
          component: () => import('../views/about.vue'),
        },
      ]
    }


  ]
})
